package com.atguigu05._super.ex3;

//import com.atguigu01._this.ex2.Acount;
import com.atguigu05._super.ex3.Account;

public class AccountTest {
    public static void main(String[] args) {
        Account a1=new Account(1122,20000,0.045);
        a1.withdraw(30000);
        a1.deposit(500);
        System.out.println();
        CheckAccount checkAccount1=new CheckAccount(1122,20000,0.045,5000);
        checkAccount1.setOverdraft(5000);
        checkAccount1.withdraw(5000);
        System.out.println(checkAccount1.getBalance());
        System.out.println(checkAccount1.getOverdraft());
        System.out.println();
        checkAccount1.withdraw(18000);
        System.out.println(checkAccount1.getBalance());
        System.out.println(checkAccount1.getOverdraft());
        System.out.println();
        checkAccount1.withdraw(3000);
        System.out.println(checkAccount1.getBalance());
        System.out.println(checkAccount1.getOverdraft());
    }
}
